#ifndef __MOTOR_H_
#define __MOTOR_H_

typedef enum
{
    STOPM = 1,
    MOTORTEST,
    STAND,
    CLOSELOOP,
    RELEASE,
}CarMode;

typedef struct
{
    CarMode Mode;
    uint8 Condition;
}CarInfotypedef;

void MotorInit();
void MotorPwmFlash();
void ALL_Out(void);
int16 PWM_Limit(float PWM,int16 max);
extern float Right_out,Left_out;
extern CarInfotypedef CarInfo;
extern uint8 loseflag;
#endif